\hypertarget{class_simulation}{
\section{Simulation Class Reference}
\label{class_simulation}\index{Simulation@{Simulation}}
}


creates all other objects for the simulation and provides central management and communication with all of them and the gui  




{\ttfamily \#include $<$Simulation.h$>$}



Collaboration diagram for Simulation:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=600pt]{class_simulation__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Slots}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{class_simulation_a4013fd48f4c835032cc250a80964b5a4}{updateCameraZoom} (const int \_\-depth)
\begin{DoxyCompactList}\small\item\em called when the camera zoom slider value is changed in the GUI; it slides the camera along its N vector \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{class_simulation_a755afcafbb88352fbc4ae3fab1d701fb}{Simulation} (QWidget $\ast$\_\-parent)
\begin{DoxyCompactList}\small\item\em ctor \end{DoxyCompactList}\item 
\hyperlink{class_simulation_a80fad3f57dfaf195a36f7bc49bc88279}{$\sim$Simulation} ()
\begin{DoxyCompactList}\small\item\em dtor \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a0ad9f5072536b632f12c32a105f441b4}{keyPress} (QKeyEvent $\ast$\_\-event)
\begin{DoxyCompactList}\small\item\em handle keypress events \end{DoxyCompactList}\item 
\hyperlink{class_solver}{Solver} $\ast$ \hyperlink{class_simulation_ad0c3499f98591f654489add006b927c6}{getSolver} () const 
\begin{DoxyCompactList}\small\item\em returns the solver of the simulation \end{DoxyCompactList}\item 
\hyperlink{class_environment}{Environment} $\ast$ \hyperlink{class_simulation_aaec2b0edd7669a03262121834b2bef8e}{getEnvironment} () const 
\begin{DoxyCompactList}\small\item\em returns the environment object \end{DoxyCompactList}\item 
\hyperlink{class_integration}{Integration} $\ast$ \hyperlink{class_simulation_aed80e4e32c9f3c27cce31624e9ec9855}{getIntegration} () const 
\begin{DoxyCompactList}\small\item\em returns the integration object \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_acb3f9b6452f68b267e110c0098c3c46e}{setup2DTopView} ()
\begin{DoxyCompactList}\small\item\em this method is used to setup the 2D top view \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a5fa8ed10cec2fd5141843e605ecb8c11}{setup2DFrontView} ()
\begin{DoxyCompactList}\small\item\em this method is used to setup the 2D front view \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a9cc32fae74d0e48ad7bd6aa23ba49eac}{toggleCache} ()
\begin{DoxyCompactList}\small\item\em this method toggles the cache timer \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_aed3abe33551f1826246230827cbaa71b}{toggleAutomaticCacheFlush} ()
\begin{DoxyCompactList}\small\item\em this method toggles the automatic cache flush timer \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_ae0b5c44bbf3d36c84c91dd872aabf243}{updateFPSTimer} ()
\begin{DoxyCompactList}\small\item\em this method updates the states of timers after the simulation of fluid is started/stopped \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_abdc9f52e8b9415e51c502da5ca58a3fe}{flushCache} ()
\begin{DoxyCompactList}\small\item\em this method flushes the cache to disk \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_a30a9053f2102d1c5eabe9c62b2919917}{getCacheEnabled} () const 
\begin{DoxyCompactList}\small\item\em return the whether cache is enabled \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a89f0fce21bdfc7070a0c4d536164f41e}{getCacheSamplingInterval} () const 
\begin{DoxyCompactList}\small\item\em return cache samping interval \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_a1a56ce1de963510b235326392901f4ab}{getCacheAutomaticFlushEnabled} () const 
\begin{DoxyCompactList}\small\item\em return whether automatic cache flushing is enabled \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a96010e0eaed3c43d75867c8215917e6b}{getCacheAutomaticFlushInterval} () const 
\begin{DoxyCompactList}\small\item\em return automatic cache flushing interval \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_a6130b8f9648323c2707fe8c84595e6de}{getCacheExportRBDEnabled} () const 
\begin{DoxyCompactList}\small\item\em return whether rbd is cached \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_a33d025f4b8bea9fee08c6051ac17b7b3}{getCacheExportBoundaryEnabled} () const 
\begin{DoxyCompactList}\small\item\em return boundary is cached \end{DoxyCompactList}\item 
std::string \hyperlink{class_simulation_a4d868bd2e1c2ddcff72b86948e8f08df}{getCachePath} () const 
\begin{DoxyCompactList}\small\item\em return the path of the cache on disk \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_af5cc7d642bff6861b4ee2ca43bb9fc97}{setCacheEnabled} (const bool \_\-v)
\begin{DoxyCompactList}\small\item\em set flag to determine whether cache is enabled \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a3a87685ffa6803a9f1bd734c073457fc}{setCacheSamplingInterval} (const int \_\-v)
\begin{DoxyCompactList}\small\item\em return cache samping interval \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a19cb8a965ede0f592864fb0c3473e020}{setCacheAutomaticFlushEnabled} (const bool \_\-v)
\begin{DoxyCompactList}\small\item\em set flag to determine whether automatic cache flushing is enabled \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_aa952718ebd3d5583556e10e7fb98dd7f}{setCacheAutomaticFlushInterval} (const int \_\-v)
\begin{DoxyCompactList}\small\item\em return automatic cache flushing interval \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a92de3ffdc52af767508e341c731b54a7}{setCacheExportRBDEnabled} (const bool \_\-v)
\begin{DoxyCompactList}\small\item\em set flag to determine whether rbd is cached \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a7feaf359b5e698edf203683509c46c75}{setCacheExportBoundaryEnabled} (const bool \_\-v)
\begin{DoxyCompactList}\small\item\em set flag to determine whether boundary is cached \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Protected Member Functions}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{class_simulation_ad41df381fbea7ecf06ba90f64d29722d}{initializeGL} ()
\begin{DoxyCompactList}\small\item\em called when the window context is created \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a39d898714c1ed73be21522cc1cb35be5}{resizeGL} (const int \_\-w, const int \_\-h)
\begin{DoxyCompactList}\small\item\em called whenever the window is re-\/sized \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a328b9837a8dd98b459d59b9adbb29d48}{paintGL} ()
\begin{DoxyCompactList}\small\item\em main gl drawing method that is called whenever the window needs to be re-\/drawn \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Slots}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{class_simulation_af3b154e974820cacf90de4f5ed1fd64f}{processFPS} ()
\begin{DoxyCompactList}\small\item\em this method is called at every fps timer tick \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a6b39c77edfacb7c2250ed36355a5475b}{processSimulationCache} ()
\begin{DoxyCompactList}\small\item\em this method is called at every simulation timer tick \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_ad8a4c5ca0f9570817c72e61839e0dbfa}{processSimulationCacheAutoFlush} ()
\begin{DoxyCompactList}\small\item\em this method is called to automatically flush the cache \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Member Functions}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{class_simulation_a75e0e6b11b3c022ef533a5bab80cffe6}{timerEvent} (QTimerEvent $\ast$\_\-event)
\begin{DoxyCompactList}\small\item\em the timer event triggered from the timers \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a7a3202253b565b159ade70bb3336e553}{createCamera} ()
\begin{DoxyCompactList}\small\item\em this method create our camera \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a7db9efc6fcee168c73c43fc508d08e3c}{createLight} ()
\begin{DoxyCompactList}\small\item\em this method create our light \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a01ba14e5926aa23d932265896ffdeda9}{displayHelp} ()
\begin{DoxyCompactList}\small\item\em this method display the text help overlay on the screen \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_add8dbadd7c35c4c3ee22d0ca5ec249d5}{mouseMoveEvent} (QMouseEvent $\ast$\_\-event)
\begin{DoxyCompactList}\small\item\em this method is called every time a mouse is moved \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a0be33a6cb531ff3bdba0de30ec44d9fb}{mousePressEvent} (QMouseEvent $\ast$\_\-event)
\begin{DoxyCompactList}\small\item\em this method is called everytime the mouse button is pressed \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a96fb232ec345883d24448bc2fde53fca}{mouseReleaseEvent} (QMouseEvent $\ast$\_\-event)
\begin{DoxyCompactList}\small\item\em this method is called everytime the mouse button is released \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a5880e9d70e7abac27866eb494c7d141c}{initialiseSimulation} ()
\begin{DoxyCompactList}\small\item\em this method is called to initialise all the objects/params of the simulation \end{DoxyCompactList}\item 
void \hyperlink{class_simulation_a1ce23e3ffdcb99b873959267de7229c4}{deleteSimulationObjects} ()
\begin{DoxyCompactList}\small\item\em this method is called to delete all the objects of the simulation \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
int \hyperlink{class_simulation_a5611b623f192c406d20d99cf99cbd0d9}{m\_\-spinXFace}
\begin{DoxyCompactList}\small\item\em the x rotation mouse value \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_acaba6e4bd63518e5edd5443f6d10467c}{m\_\-spinYFace}
\begin{DoxyCompactList}\small\item\em the y rotation mouse value \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_abecf7cd8f4966dd8e19776fecd2be11c}{m\_\-rotate}
\begin{DoxyCompactList}\small\item\em flag to indicate if the mouse button is pressed when dragging \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a6422d3666ba6798f24b26efeb282732b}{m\_\-origX}
\begin{DoxyCompactList}\small\item\em the previous x mouse value \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_aeddd48fda58be3d3101acd9089bdb59e}{m\_\-origY}
\begin{DoxyCompactList}\small\item\em the previous y mouse value \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a824bd0db2421e8a1129837395ee938d4}{m\_\-moveX}
\begin{DoxyCompactList}\small\item\em right mouse camera movement x value \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a9ae645b702669c78be080ee35dcfc656}{m\_\-moveY}
\begin{DoxyCompactList}\small\item\em right mouse camera movement y value \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_aa585390cafbfeb3cdd7e4da129f27ad2}{m\_\-move}
\begin{DoxyCompactList}\small\item\em flag to indicate if the right mouse is pressed for (x,y) mouse movement \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_aa2942ca701a2560de7f3bc4aa5c36cf6}{m\_\-origMoveX}
\begin{DoxyCompactList}\small\item\em starting x position of the right mouse \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a156d1e72405c62e75207979bfdf8aa0d}{m\_\-origMoveY}
\begin{DoxyCompactList}\small\item\em starting y position of the right mouse \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_a59064177bd41ff1e01feb00afcf4b487}{m\_\-drawHelp}
\begin{DoxyCompactList}\small\item\em toggle help flag \end{DoxyCompactList}\item 
float \hyperlink{class_simulation_abda6a0ce09dba152142cd8b779a235ba}{m\_\-aspect}
\begin{DoxyCompactList}\small\item\em aspect ratio of the camera \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a487a8da0a159a86159b39b0fb0a7ea68}{m\_\-mouseMoveSensitivity}
\begin{DoxyCompactList}\small\item\em mouse move sensitivity \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a457b9396fc6681443f704b3ed17b61d5}{m\_\-frameRate}
\begin{DoxyCompactList}\small\item\em frame update rate \end{DoxyCompactList}\item 
ngl::TransformStack \hyperlink{class_simulation_ae8af4283c95bf52522f7cae6e58fa74b}{m\_\-transformStack}
\begin{DoxyCompactList}\small\item\em global transform stack \end{DoxyCompactList}\item 
ngl::Light \hyperlink{class_simulation_a32878b0a743e6bd06aa435560618bcca}{m\_\-light}
\begin{DoxyCompactList}\small\item\em ngl light object \end{DoxyCompactList}\item 
ngl::Camera \hyperlink{class_simulation_af0c9404e4c5c24c154283fc7f843d828}{m\_\-camera}
\begin{DoxyCompactList}\small\item\em ngl camera object \end{DoxyCompactList}\item 
\hyperlink{class_shader_library}{ShaderLibrary} $\ast$ \hyperlink{class_simulation_a83383544daf0879e0c813082c8079e86}{m\_\-shaderLibrary}
\begin{DoxyCompactList}\small\item\em shader library \end{DoxyCompactList}\item 
\hyperlink{class_solver}{Solver} $\ast$ \hyperlink{class_simulation_a642455fef792c7129fcf18887da865d9}{m\_\-solver}
\begin{DoxyCompactList}\small\item\em fluid solver \end{DoxyCompactList}\item 
\hyperlink{class_environment}{Environment} $\ast$ \hyperlink{class_simulation_a1b0107415c2dcb91934280857751b2aa}{m\_\-environment}
\begin{DoxyCompactList}\small\item\em environment \end{DoxyCompactList}\item 
\hyperlink{class_integration}{Integration} $\ast$ \hyperlink{class_simulation_a44ee516f95af7bbdce7f7853428f3a9f}{m\_\-integration}
\begin{DoxyCompactList}\small\item\em integration \end{DoxyCompactList}\item 
\hyperlink{class_cache}{Cache} $\ast$ \hyperlink{class_simulation_aae62058ff9bb93a433685384d63f26b3}{m\_\-cache}
\begin{DoxyCompactList}\small\item\em cache \end{DoxyCompactList}\item 
float \hyperlink{class_simulation_aa5b6caae07baa87fc6bf2cd2df3ce9a3}{m\_\-lastCamZ}
\begin{DoxyCompactList}\small\item\em the last depth of a camera zoom operation \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a0c8c6edf43d816404c6222dd93c49fe6}{m\_\-frameCounter}
\begin{DoxyCompactList}\small\item\em counter to keep track of number of frames for fps calculation \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a4d073bafa3112526d3b0cf9e11a1eead}{m\_\-mainSimulationTimer}
\begin{DoxyCompactList}\small\item\em main simulation timer (continuous ticking) \end{DoxyCompactList}\item 
QTimer $\ast$ \hyperlink{class_simulation_a2a4f2cfb5609a76f43fb478a0ea454f6}{m\_\-fpsTimer}
\begin{DoxyCompactList}\small\item\em fps timer with interval = 1 s \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_aed57e8a29c33ed01e10294521afababd}{m\_\-fpsTimerEnabled}
\begin{DoxyCompactList}\small\item\em fps timer toggle \end{DoxyCompactList}\item 
QTimer $\ast$ \hyperlink{class_simulation_ab0b9b0ee02566961f1cb7f7dc82c140a}{m\_\-simulationCacheTimer}
\begin{DoxyCompactList}\small\item\em simulation cache timer \end{DoxyCompactList}\item 
QTimer $\ast$ \hyperlink{class_simulation_a90dc06d8b8ae5e1897f72895d3067943}{m\_\-simulationCacheAutoFlushTimer}
\begin{DoxyCompactList}\small\item\em simulation cache autoFlush timer \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_af359882ee350f8cee694e81d415585b5}{m\_\-simulationCacheFrameNumber}
\begin{DoxyCompactList}\small\item\em cache frame number \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_acc7915a7ed4a9f75c4b4288b451433d1}{m\_\-cacheEnabled}
\begin{DoxyCompactList}\small\item\em flag to determine if cache is enabled \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_a945f9264f587eb677ccc6574ca85d65e}{m\_\-cacheSamplingInterval}
\begin{DoxyCompactList}\small\item\em cache samping interval \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_a5202d1ba26da5e3abbc1af3b5a760cd4}{m\_\-cacheAutomaticFlushEnabled}
\begin{DoxyCompactList}\small\item\em flag to determine automatic cache flushing is enabled \end{DoxyCompactList}\item 
int \hyperlink{class_simulation_afb2e47a4aa797855e428378cf1294409}{m\_\-cacheAutomaticFlushInterval}
\begin{DoxyCompactList}\small\item\em automatic cache flushing interval \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_ac7c9f2c16923e90dc8903f9083ca9e2c}{m\_\-cacheExportRBDEnabled}
\begin{DoxyCompactList}\small\item\em flag to determine if rbd is cached \end{DoxyCompactList}\item 
bool \hyperlink{class_simulation_a789806513f6abfc274479a379f499c7d}{m\_\-cacheExportBoundaryEnabled}
\begin{DoxyCompactList}\small\item\em flag to determine if boundary is cached \end{DoxyCompactList}\item 
std::string \hyperlink{class_simulation_a3d4535e9d5af4426e1c83fcbc3517449}{m\_\-cachePath}
\begin{DoxyCompactList}\small\item\em the path of the cache on disk \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
creates all other objects for the simulation and provides central management and communication with all of them and the gui 

Definition at line 28 of file Simulation.h.



\subsection{Constructor \& Destructor Documentation}
\hypertarget{class_simulation_a755afcafbb88352fbc4ae3fab1d701fb}{
\index{Simulation@{Simulation}!Simulation@{Simulation}}
\index{Simulation@{Simulation}!Simulation@{Simulation}}
\subsubsection[{Simulation}]{\setlength{\rightskip}{0pt plus 5cm}Simulation::Simulation (
\begin{DoxyParamCaption}
\item[{QWidget $\ast$}]{\_\-parent}
\end{DoxyParamCaption}
)}}
\label{class_simulation_a755afcafbb88352fbc4ae3fab1d701fb}


ctor 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-parent} & the parent window to create the GL context in \\
\hline
\end{DoxyParams}


Definition at line 21 of file Simulation.cpp.


\begin{DoxyCode}
                  :
                QGLWidget(_parent)
{
    // set this widget to have the initial keyboard focus
    setFocusPolicy(Qt::StrongFocus);
    setFocus();

    //initialise simulation
    initialiseSimulation();
}
\end{DoxyCode}
\hypertarget{class_simulation_a80fad3f57dfaf195a36f7bc49bc88279}{
\index{Simulation@{Simulation}!$\sim$Simulation@{$\sim$Simulation}}
\index{$\sim$Simulation@{$\sim$Simulation}!Simulation@{Simulation}}
\subsubsection[{$\sim$Simulation}]{\setlength{\rightskip}{0pt plus 5cm}Simulation::$\sim$Simulation (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{class_simulation_a80fad3f57dfaf195a36f7bc49bc88279}


dtor 



Definition at line 112 of file Simulation.cpp.



References deleteSimulationObjects().


\begin{DoxyCode}
{
    //clean up ngl
    std::cout << "\nNGL Cleanup" << std::endl;

    ngl::NGLInit* Init = ngl::NGLInit::instance();
    Init->NGLQuit();
    std::cout << "NGL shut down safely\n" << std::endl;

    //delete all current objects
    deleteSimulationObjects();
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a80fad3f57dfaf195a36f7bc49bc88279_cgraph}
\end{center}
\end{figure}




\subsection{Member Function Documentation}
\hypertarget{class_simulation_a7a3202253b565b159ade70bb3336e553}{
\index{Simulation@{Simulation}!createCamera@{createCamera}}
\index{createCamera@{createCamera}!Simulation@{Simulation}}
\subsubsection[{createCamera}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::createCamera (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a7a3202253b565b159ade70bb3336e553}


this method create our camera 



Definition at line 353 of file Simulation.cpp.



References Configuration::initialiseCamera(), m\_\-aspect, and m\_\-camera.


\begin{DoxyCode}
{
    //create camera from config parameters
    m_camera = Configuration::initialiseCamera(m_aspect);
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a7a3202253b565b159ade70bb3336e553_cgraph}
\end{center}
\end{figure}




Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=396pt]{class_simulation_a7a3202253b565b159ade70bb3336e553_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a7db9efc6fcee168c73c43fc508d08e3c}{
\index{Simulation@{Simulation}!createLight@{createLight}}
\index{createLight@{createLight}!Simulation@{Simulation}}
\subsubsection[{createLight}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::createLight (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a7db9efc6fcee168c73c43fc508d08e3c}


this method create our light 



Definition at line 359 of file Simulation.cpp.



References Configuration::initialiseLight(), and m\_\-light.


\begin{DoxyCode}
{
    //set a material
    ngl::Material m(ngl::PEWTER); m.use();
    m.setSpecular(ngl::Colour(1,1,1));
    m.setSpecularExponent(0.2);;

    //create our light from config and enable it
    m_light = Configuration::initialiseLight(); m_light.enable();
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a7db9efc6fcee168c73c43fc508d08e3c_cgraph}
\end{center}
\end{figure}




Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=382pt]{class_simulation_a7db9efc6fcee168c73c43fc508d08e3c_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a1ce23e3ffdcb99b873959267de7229c4}{
\index{Simulation@{Simulation}!deleteSimulationObjects@{deleteSimulationObjects}}
\index{deleteSimulationObjects@{deleteSimulationObjects}!Simulation@{Simulation}}
\subsubsection[{deleteSimulationObjects}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::deleteSimulationObjects (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a1ce23e3ffdcb99b873959267de7229c4}


this method is called to delete all the objects of the simulation 



Definition at line 100 of file Simulation.cpp.



References m\_\-environment, m\_\-integration, m\_\-mainSimulationTimer, m\_\-shaderLibrary, and m\_\-solver.


\begin{DoxyCode}
{
    //kill timers
    killTimer(m_mainSimulationTimer);

    //delete all the current objects associated with the simulation
    delete m_shaderLibrary;
    delete m_solver;
    delete m_environment;
    delete m_integration;
}
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a1ce23e3ffdcb99b873959267de7229c4_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a01ba14e5926aa23d932265896ffdeda9}{
\index{Simulation@{Simulation}!displayHelp@{displayHelp}}
\index{displayHelp@{displayHelp}!Simulation@{Simulation}}
\subsubsection[{displayHelp}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::displayHelp (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a01ba14e5926aa23d932265896ffdeda9}


this method display the text help overlay on the screen 



Definition at line 216 of file Simulation.cpp.



References m\_\-drawHelp.


\begin{DoxyCode}
{
    //display help menu
    if (m_drawHelp == true)
    {
        // first we need to fallback to the fixed functionality GL pipeline
        glUseProgram(0);

        //create font
        QFont font;
        font.setBold(false);
        font.setPointSize(12);
        glColor3f(1,1,0);

        //display debug and stats info
        QString text;
   }

}
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=338pt]{class_simulation_a01ba14e5926aa23d932265896ffdeda9_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_abdc9f52e8b9415e51c502da5ca58a3fe}{
\index{Simulation@{Simulation}!flushCache@{flushCache}}
\index{flushCache@{flushCache}!Simulation@{Simulation}}
\subsubsection[{flushCache}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::flushCache (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{class_simulation_abdc9f52e8b9415e51c502da5ca58a3fe}


this method flushes the cache to disk 



Definition at line 488 of file Simulation.cpp.



References Cache::flushCache(), m\_\-cache, and m\_\-cachePath.


\begin{DoxyCode}
{
    //flush cache to file
    m_cache->flushCache(m_cachePath);

    std::cout << "Cache Flushed\n";
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_abdc9f52e8b9415e51c502da5ca58a3fe_cgraph}
\end{center}
\end{figure}




Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_abdc9f52e8b9415e51c502da5ca58a3fe_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a1a56ce1de963510b235326392901f4ab}{
\index{Simulation@{Simulation}!getCacheAutomaticFlushEnabled@{getCacheAutomaticFlushEnabled}}
\index{getCacheAutomaticFlushEnabled@{getCacheAutomaticFlushEnabled}!Simulation@{Simulation}}
\subsubsection[{getCacheAutomaticFlushEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool Simulation::getCacheAutomaticFlushEnabled (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a1a56ce1de963510b235326392901f4ab}


return whether automatic cache flushing is enabled 



Definition at line 81 of file Simulation.h.



References m\_\-cacheAutomaticFlushEnabled.


\begin{DoxyCode}
{ return m_cacheAutomaticFlushEnabled; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a1a56ce1de963510b235326392901f4ab_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a96010e0eaed3c43d75867c8215917e6b}{
\index{Simulation@{Simulation}!getCacheAutomaticFlushInterval@{getCacheAutomaticFlushInterval}}
\index{getCacheAutomaticFlushInterval@{getCacheAutomaticFlushInterval}!Simulation@{Simulation}}
\subsubsection[{getCacheAutomaticFlushInterval}]{\setlength{\rightskip}{0pt plus 5cm}int Simulation::getCacheAutomaticFlushInterval (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a96010e0eaed3c43d75867c8215917e6b}


return automatic cache flushing interval 



Definition at line 84 of file Simulation.h.



References m\_\-cacheAutomaticFlushInterval.


\begin{DoxyCode}
{ return m_cacheAutomaticFlushInterval; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a96010e0eaed3c43d75867c8215917e6b_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a30a9053f2102d1c5eabe9c62b2919917}{
\index{Simulation@{Simulation}!getCacheEnabled@{getCacheEnabled}}
\index{getCacheEnabled@{getCacheEnabled}!Simulation@{Simulation}}
\subsubsection[{getCacheEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool Simulation::getCacheEnabled (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a30a9053f2102d1c5eabe9c62b2919917}


return the whether cache is enabled 



Definition at line 75 of file Simulation.h.



References m\_\-cacheEnabled.


\begin{DoxyCode}
{ return m_cacheEnabled; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a30a9053f2102d1c5eabe9c62b2919917_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a33d025f4b8bea9fee08c6051ac17b7b3}{
\index{Simulation@{Simulation}!getCacheExportBoundaryEnabled@{getCacheExportBoundaryEnabled}}
\index{getCacheExportBoundaryEnabled@{getCacheExportBoundaryEnabled}!Simulation@{Simulation}}
\subsubsection[{getCacheExportBoundaryEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool Simulation::getCacheExportBoundaryEnabled (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a33d025f4b8bea9fee08c6051ac17b7b3}


return boundary is cached 



Definition at line 90 of file Simulation.h.



References m\_\-cacheExportBoundaryEnabled.


\begin{DoxyCode}
{ return m_cacheExportBoundaryEnabled; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a33d025f4b8bea9fee08c6051ac17b7b3_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a6130b8f9648323c2707fe8c84595e6de}{
\index{Simulation@{Simulation}!getCacheExportRBDEnabled@{getCacheExportRBDEnabled}}
\index{getCacheExportRBDEnabled@{getCacheExportRBDEnabled}!Simulation@{Simulation}}
\subsubsection[{getCacheExportRBDEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool Simulation::getCacheExportRBDEnabled (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a6130b8f9648323c2707fe8c84595e6de}


return whether rbd is cached 



Definition at line 87 of file Simulation.h.



References m\_\-cacheExportRBDEnabled.


\begin{DoxyCode}
{ return m_cacheExportRBDEnabled; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a6130b8f9648323c2707fe8c84595e6de_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a4d868bd2e1c2ddcff72b86948e8f08df}{
\index{Simulation@{Simulation}!getCachePath@{getCachePath}}
\index{getCachePath@{getCachePath}!Simulation@{Simulation}}
\subsubsection[{getCachePath}]{\setlength{\rightskip}{0pt plus 5cm}std::string Simulation::getCachePath (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a4d868bd2e1c2ddcff72b86948e8f08df}


return the path of the cache on disk 



Definition at line 93 of file Simulation.h.



References m\_\-cachePath.


\begin{DoxyCode}
{ return m_cachePath; }
\end{DoxyCode}
\hypertarget{class_simulation_a89f0fce21bdfc7070a0c4d536164f41e}{
\index{Simulation@{Simulation}!getCacheSamplingInterval@{getCacheSamplingInterval}}
\index{getCacheSamplingInterval@{getCacheSamplingInterval}!Simulation@{Simulation}}
\subsubsection[{getCacheSamplingInterval}]{\setlength{\rightskip}{0pt plus 5cm}int Simulation::getCacheSamplingInterval (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a89f0fce21bdfc7070a0c4d536164f41e}


return cache samping interval 



Definition at line 78 of file Simulation.h.



References m\_\-cacheSamplingInterval.


\begin{DoxyCode}
{ return m_cacheSamplingInterval; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a89f0fce21bdfc7070a0c4d536164f41e_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_aaec2b0edd7669a03262121834b2bef8e}{
\index{Simulation@{Simulation}!getEnvironment@{getEnvironment}}
\index{getEnvironment@{getEnvironment}!Simulation@{Simulation}}
\subsubsection[{getEnvironment}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Environment}$\ast$ Simulation::getEnvironment (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_aaec2b0edd7669a03262121834b2bef8e}


returns the environment object 



Definition at line 50 of file Simulation.h.



References m\_\-environment.


\begin{DoxyCode}
{ return  m_environment; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_aaec2b0edd7669a03262121834b2bef8e_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_aed80e4e32c9f3c27cce31624e9ec9855}{
\index{Simulation@{Simulation}!getIntegration@{getIntegration}}
\index{getIntegration@{getIntegration}!Simulation@{Simulation}}
\subsubsection[{getIntegration}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Integration}$\ast$ Simulation::getIntegration (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_aed80e4e32c9f3c27cce31624e9ec9855}


returns the integration object 



Definition at line 53 of file Simulation.h.



References m\_\-integration.


\begin{DoxyCode}
{ return  m_integration; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_aed80e4e32c9f3c27cce31624e9ec9855_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_ad0c3499f98591f654489add006b927c6}{
\index{Simulation@{Simulation}!getSolver@{getSolver}}
\index{getSolver@{getSolver}!Simulation@{Simulation}}
\subsubsection[{getSolver}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Solver}$\ast$ Simulation::getSolver (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_ad0c3499f98591f654489add006b927c6}


returns the solver of the simulation 



Definition at line 47 of file Simulation.h.



References m\_\-solver.


\begin{DoxyCode}
{ return  m_solver; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_ad0c3499f98591f654489add006b927c6_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a5880e9d70e7abac27866eb494c7d141c}{
\index{Simulation@{Simulation}!initialiseSimulation@{initialiseSimulation}}
\index{initialiseSimulation@{initialiseSimulation}!Simulation@{Simulation}}
\subsubsection[{initialiseSimulation}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::initialiseSimulation (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a5880e9d70e7abac27866eb494c7d141c}


this method is called to initialise all the objects/params of the simulation 



Definition at line 34 of file Simulation.cpp.



References createCamera(), createLight(), Configuration::initialiseWindow(), m\_\-cache, m\_\-cacheAutomaticFlushEnabled, m\_\-cacheAutomaticFlushInterval, m\_\-cacheEnabled, m\_\-cacheExportBoundaryEnabled, m\_\-cacheExportRBDEnabled, m\_\-cachePath, m\_\-cacheSamplingInterval, m\_\-camera, m\_\-drawHelp, m\_\-environment, m\_\-fpsTimer, m\_\-fpsTimerEnabled, m\_\-frameCounter, m\_\-frameRate, m\_\-integration, m\_\-lastCamZ, m\_\-mainSimulationTimer, m\_\-mouseMoveSensitivity, m\_\-move, m\_\-moveX, m\_\-moveY, m\_\-rotate, m\_\-shaderLibrary, m\_\-simulationCacheAutoFlushTimer, m\_\-simulationCacheFrameNumber, m\_\-simulationCacheTimer, m\_\-solver, m\_\-spinXFace, m\_\-spinYFace, processFPS(), processSimulationCache(), processSimulationCacheAutoFlush(), SEMI\_\-IMPLICIT\_\-EULER, toggleAutomaticCacheFlush(), toggleCache(), and updateFPSTimer().


\begin{DoxyCode}
{
    //initialise mouse rotation values
    m_rotate=false;
    m_spinXFace=-20;
    m_spinYFace=-40;

    //initialise mouse movement values
    m_move=false;
    m_moveX=0;
    m_moveY=0;

    //init framerate and mouse move sensitivity
    ngl::Real timestep = 0;
    Configuration::initialiseWindow(m_frameRate, m_mouseMoveSensitivity, timestep
      , m_fpsTimerEnabled, m_cacheEnabled, m_cacheSamplingInterval, 
      m_cacheAutomaticFlushEnabled, m_cacheAutomaticFlushInterval, 
      m_cacheExportRBDEnabled, m_cacheExportBoundaryEnabled, m_cachePath);

    //create camera
    createCamera();

    //create light
    createLight();

    //initialise our shader library to \0null
    m_shaderLibrary = 0;

    //create the fluid solver
    m_solver = new Solver();

    //create the environment
    m_environment = new Environment();

    //create the integration
    m_integration = new Integration(SEMI_IMPLICIT_EULER, timestep);

    //create the simulation cache
    m_cache = new Cache();

    //start main timer
    m_mainSimulationTimer = startTimer(m_frameRate);

    //initialise fps timer
    m_fpsTimer = new QTimer(this);
    connect(m_fpsTimer, SIGNAL(timeout()), this, SLOT(processFPS()));
    m_fpsTimer->setInterval(1000);
    m_frameCounter = 0;
    updateFPSTimer();

    //initialise cache timer
    m_simulationCacheTimer = new QTimer(this);
    connect(m_simulationCacheTimer, SIGNAL(timeout()), this, SLOT(
      processSimulationCache()));
    m_simulationCacheFrameNumber = -1;

    //initialise cache autoFlush timer
    m_simulationCacheAutoFlushTimer = new QTimer(this);
    connect(m_simulationCacheAutoFlushTimer, SIGNAL(timeout()), this, SLOT(
      processSimulationCacheAutoFlush()));

    toggleCache();
    toggleAutomaticCacheFlush();

    //hide help by default
    m_drawHelp = false;

    //initial camera z value
    m_lastCamZ = m_camera.getEye().m_z;
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a5880e9d70e7abac27866eb494c7d141c_cgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_ad41df381fbea7ecf06ba90f64d29722d}{
\index{Simulation@{Simulation}!initializeGL@{initializeGL}}
\index{initializeGL@{initializeGL}!Simulation@{Simulation}}
\subsubsection[{initializeGL}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::initializeGL (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{class_simulation_ad41df381fbea7ecf06ba90f64d29722d}


called when the window context is created 



Definition at line 125 of file Simulation.cpp.



References Solver::initialiseDrawing(), Environment::loadGeometry(), m\_\-camera, m\_\-environment, m\_\-shaderLibrary, m\_\-solver, and ShaderLibrary::updateViewProjection().


\begin{DoxyCode}
{
    //init glew
    ngl::NGLInit* Init = ngl::NGLInit::instance();
    Init->initGlew();

    // enable depth testing for drawing
    glEnable(GL_DEPTH_TEST);

    //initialise shaders
    m_shaderLibrary = new ShaderLibrary();
    m_shaderLibrary->updateViewProjection(&m_camera);

    //initialise fluid drawing
    m_solver->initialiseDrawing();

    //initialise environment drawing
    m_environment->loadGeometry();

    //create vbo for plane grid
    ngl::VBOPrimitives *prim=ngl::VBOPrimitives::instance();
    prim->createVBOQuadPlane("plane",20,20,1,1,ngl::Vector(0,1,0));

    //create vbo for cube fluid plane [10 x 10 grid]
    prim->createVBOQuadPlane("fluidPlaneLayer", 9, 9, 9, 9, ngl::Vector(0, 1, 0))
      ;
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_ad41df381fbea7ecf06ba90f64d29722d_cgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a0ad9f5072536b632f12c32a105f441b4}{
\index{Simulation@{Simulation}!keyPress@{keyPress}}
\index{keyPress@{keyPress}!Simulation@{Simulation}}
\subsubsection[{keyPress}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::keyPress (
\begin{DoxyParamCaption}
\item[{QKeyEvent $\ast$}]{\_\-event}
\end{DoxyParamCaption}
)}}
\label{class_simulation_a0ad9f5072536b632f12c32a105f441b4}


handle keypress events 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-event} & the Qt Event structure, holding information about keypresses \\
\hline
\end{DoxyParams}


Definition at line 256 of file Simulation.cpp.



References Solver::injectParticles(), m\_\-cacheEnabled, m\_\-environment, m\_\-integration, m\_\-solver, toggleCache(), Solver::toggleEnableAutoFluidUpdate(), Solver::toggleNextHoseableFluid(), Solver::updateFluid(), and updateFPSTimer().


\begin{DoxyCode}
{
    switch (_event->key())
    {
        //debug info
//        case Qt::Key_D : { m_drawHelp ^=true; break; }

        //single step fluid update
        case Qt::Key_W : { m_solver->updateFluid(m_environment, m_integration); b
      reak; }

        //toggle timer to update fluid
        case Qt::Key_Q : { m_solver->toggleEnableAutoFluidUpdate(); 
      updateFPSTimer(); break; }

        //inject particles in fluid solver
        case Qt::Key_A : { m_solver->injectParticles(); break; }

        //toggle to next hoseable fluid
        case Qt::Key_S : { m_solver->toggleNextHoseableFluid(); break; }

        //toggle cache timer
        case Qt::Key_C :
        {
            m_cacheEnabled = !m_cacheEnabled;
            toggleCache();

            break;
        }

        default : break;
    }

    // re-draw GL
    updateGL();
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a0ad9f5072536b632f12c32a105f441b4_cgraph}
\end{center}
\end{figure}




Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=352pt]{class_simulation_a0ad9f5072536b632f12c32a105f441b4_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_add8dbadd7c35c4c3ee22d0ca5ec249d5}{
\index{Simulation@{Simulation}!mouseMoveEvent@{mouseMoveEvent}}
\index{mouseMoveEvent@{mouseMoveEvent}!Simulation@{Simulation}}
\subsubsection[{mouseMoveEvent}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::mouseMoveEvent (
\begin{DoxyParamCaption}
\item[{QMouseEvent $\ast$}]{\_\-event}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_add8dbadd7c35c4c3ee22d0ca5ec249d5}


this method is called every time a mouse is moved 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-event} & the Qt Event structure \\
\hline
\end{DoxyParams}


Definition at line 291 of file Simulation.cpp.



References m\_\-camera, m\_\-mouseMoveSensitivity, m\_\-move, m\_\-moveX, m\_\-moveY, m\_\-origMoveX, m\_\-origMoveY, m\_\-origX, m\_\-origY, m\_\-rotate, m\_\-shaderLibrary, m\_\-spinXFace, m\_\-spinYFace, and ShaderLibrary::updateViewProjection().


\begin{DoxyCode}
{
    //as the left mouse is still pressed and it moves, we get the x and y spin va
      lue
    if(m_rotate && _event->buttons() == Qt::LeftButton)
    {
        m_spinYFace = ( m_spinYFace + (_event->x() - m_origX) ) % 360 ;
        m_spinXFace = ( m_spinXFace + (_event->y() - m_origY) ) % 360 ;
        m_origX = _event->x();
        m_origY = _event->y();

        // re-draw GL
        updateGL();
    }

    //move camera in the (x,y) plane
    if(m_move && _event->buttons() == Qt::RightButton)
    {
        m_moveX = _event->x() - m_origMoveX;
        m_moveY = _event->y() - m_origMoveY;
        m_origMoveX = _event->x();
        m_origMoveY = _event->y();

        //move camera eye n look by (dx, dy)
        m_camera.move(m_moveX / m_mouseMoveSensitivity, m_moveY / 
      m_mouseMoveSensitivity, 0);

        //update view projection matrices of camera
        m_shaderLibrary->updateViewProjection(&m_camera);

        // re-draw GL
        updateGL();
    }
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_add8dbadd7c35c4c3ee22d0ca5ec249d5_cgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a0be33a6cb531ff3bdba0de30ec44d9fb}{
\index{Simulation@{Simulation}!mousePressEvent@{mousePressEvent}}
\index{mousePressEvent@{mousePressEvent}!Simulation@{Simulation}}
\subsubsection[{mousePressEvent}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::mousePressEvent (
\begin{DoxyParamCaption}
\item[{QMouseEvent $\ast$}]{\_\-event}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a0be33a6cb531ff3bdba0de30ec44d9fb}


this method is called everytime the mouse button is pressed 


\begin{DoxyParams}{Parameters}
{\em \_\-event} & the Qt Event structure \\
\hline
\end{DoxyParams}


Definition at line 324 of file Simulation.cpp.



References m\_\-move, m\_\-origMoveX, m\_\-origMoveY, m\_\-origX, m\_\-origY, and m\_\-rotate.


\begin{DoxyCode}
{
    //keep track of origin of x,y movement for rotation
    if(_event->button() == Qt::LeftButton)
    {
        m_origX = _event->x();
        m_origY = _event->y();
        m_rotate =true;
    }

    //keep track of origin of x,y movement for tracking
    if(_event->button() == Qt::RightButton)
    {
        m_origMoveX = _event->x();
        m_origMoveY = _event->y();
        m_move =true;
    }
}
\end{DoxyCode}
\hypertarget{class_simulation_a96fb232ec345883d24448bc2fde53fca}{
\index{Simulation@{Simulation}!mouseReleaseEvent@{mouseReleaseEvent}}
\index{mouseReleaseEvent@{mouseReleaseEvent}!Simulation@{Simulation}}
\subsubsection[{mouseReleaseEvent}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::mouseReleaseEvent (
\begin{DoxyParamCaption}
\item[{QMouseEvent $\ast$}]{\_\-event}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a96fb232ec345883d24448bc2fde53fca}


this method is called everytime the mouse button is released 


\begin{DoxyParams}{Parameters}
{\em \_\-event} & the Qt Event structure \\
\hline
\end{DoxyParams}


Definition at line 343 of file Simulation.cpp.



References m\_\-move, and m\_\-rotate.


\begin{DoxyCode}
{
    //disable rotation
    if (_event->button() == Qt::LeftButton) m_rotate=false;

    //disable tracking
    if (_event->button() == Qt::RightButton) m_move=false;

}
\end{DoxyCode}
\hypertarget{class_simulation_a328b9837a8dd98b459d59b9adbb29d48}{
\index{Simulation@{Simulation}!paintGL@{paintGL}}
\index{paintGL@{paintGL}!Simulation@{Simulation}}
\subsubsection[{paintGL}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::paintGL (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{class_simulation_a328b9837a8dd98b459d59b9adbb29d48}


main gl drawing method that is called whenever the window needs to be re-\/drawn 



Definition at line 171 of file Simulation.cpp.



References displayHelp(), Environment::draw(), Solver::getDrawHoseMarker(), Solver::getHoseCenter(), m\_\-environment, m\_\-shaderLibrary, m\_\-solver, m\_\-spinXFace, m\_\-spinYFace, m\_\-transformStack, Solver::render(), ShaderLibrary::updateColor(), ShaderLibrary::updateModel(), and ShaderLibrary::useShader().


\begin{DoxyCode}
{
    // clear the screen and depth buffer
    glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
    glClearColor(0.4, 0.4, 0.4, 1);

    //update tx stack with global mouse movements
    ngl::Transformation trans;
    trans.setRotation(m_spinXFace, m_spinYFace, 0);
    m_transformStack.setGlobal(trans);

    m_shaderLibrary->useShader("Light");

    //visualise fluid state
    m_solver->render(m_transformStack, m_shaderLibrary, "Light");

    //draw environment
    m_environment->draw(m_transformStack, m_shaderLibrary, "Light", "Light");

    //draw grid and reference origin
    ngl::VBOPrimitives *prim=ngl::VBOPrimitives::instance();

    //draw solver hose marker if enabled
    if (m_solver->getDrawHoseMarker())
    {
        m_transformStack.pushTransform();
        {
            m_transformStack.getCurrentTransform().setPosition(m_solver->
      getHoseCenter().m_x, m_solver->getHoseCenter().m_y, m_solver->getHoseCenter().m_z
      );
            m_transformStack.getCurrentTransform().setScale(0.3,0.3,0.3);

            //pass vertex info to shader
            m_shaderLibrary->updateModel("Light", m_transformStack.getCurrAndGlob
      al().getMatrix(), true);

            //pass color info to shader
            m_shaderLibrary->updateColor("Light", ngl::Colour(1, 1, 1), false);

            prim->draw("cube");
        }
        m_transformStack.popTransform();
    }

    //display stats menu
    displayHelp();
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a328b9837a8dd98b459d59b9adbb29d48_cgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_af3b154e974820cacf90de4f5ed1fd64f}{
\index{Simulation@{Simulation}!processFPS@{processFPS}}
\index{processFPS@{processFPS}!Simulation@{Simulation}}
\subsubsection[{processFPS}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::processFPS (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private, slot\mbox{]}}}}
\label{class_simulation_af3b154e974820cacf90de4f5ed1fd64f}


this method is called at every fps timer tick 



Definition at line 428 of file Simulation.cpp.



References m\_\-frameCounter.


\begin{DoxyCode}
{
    std::cout << "FPS : " << m_frameCounter << "\n";
    m_frameCounter = 0;
}
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=388pt]{class_simulation_af3b154e974820cacf90de4f5ed1fd64f_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a6b39c77edfacb7c2250ed36355a5475b}{
\index{Simulation@{Simulation}!processSimulationCache@{processSimulationCache}}
\index{processSimulationCache@{processSimulationCache}!Simulation@{Simulation}}
\subsubsection[{processSimulationCache}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::processSimulationCache (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private, slot\mbox{]}}}}
\label{class_simulation_a6b39c77edfacb7c2250ed36355a5475b}


this method is called at every simulation timer tick 



Definition at line 460 of file Simulation.cpp.



References Cache::addItem(), BOUNDARY\_\-CACHE, CAPSULE\_\-CACHE, FLUID\_\-CACHE, Environment::getBoundaryNameList(), Environment::getBoundaryPositionList(), Environment::getCapsuleNameList(), Environment::getCapsulePositionList(), Solver::getNameList(), Environment::getObstacleEnabled(), Solver::getPositionList(), Environment::getSphereNameList(), Environment::getSpherePositionList(), m\_\-cache, m\_\-cacheEnabled, m\_\-cacheExportBoundaryEnabled, m\_\-cacheExportRBDEnabled, m\_\-environment, m\_\-simulationCacheFrameNumber, m\_\-solver, and SPHERE\_\-CACHE.


\begin{DoxyCode}
{
    if (m_cacheEnabled)
    {
        ++m_simulationCacheFrameNumber;

        //create a fluid cache item and add it to the cache
        m_cache->addItem(CacheItem(m_solver->getPositionList(), m_solver->
      getNameList(), m_simulationCacheFrameNumber, FLUID_CACHE));

        //create a boundary cache item and add it to the cache if enabled
        if (m_cacheExportBoundaryEnabled) m_cache->addItem(CacheItem(
      m_environment->getBoundaryPositionList(), m_environment->getBoundaryNameList(), 
      m_simulationCacheFrameNumber, BOUNDARY_CACHE));

        //create a rbd cache item and add it to the cache if enabled
        if (m_cacheExportRBDEnabled && m_environment->getObstacleEnabled())
        {
            m_cache->addItem(CacheItem(m_environment->getSpherePositionList(), 
      m_environment->getSphereNameList(), m_simulationCacheFrameNumber, SPHERE_CACHE));
      
            m_cache->addItem(CacheItem(m_environment->getCapsulePositionList(), 
      m_environment->getCapsuleNameList(), m_simulationCacheFrameNumber, CAPSULE_CACHE)
      );
        }

        std::cout << "Cached frame number : " << m_simulationCacheFrameNumber << 
      "\n";
    }
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a6b39c77edfacb7c2250ed36355a5475b_cgraph}
\end{center}
\end{figure}




Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a6b39c77edfacb7c2250ed36355a5475b_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_ad8a4c5ca0f9570817c72e61839e0dbfa}{
\index{Simulation@{Simulation}!processSimulationCacheAutoFlush@{processSimulationCacheAutoFlush}}
\index{processSimulationCacheAutoFlush@{processSimulationCacheAutoFlush}!Simulation@{Simulation}}
\subsubsection[{processSimulationCacheAutoFlush}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::processSimulationCacheAutoFlush (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private, slot\mbox{]}}}}
\label{class_simulation_ad8a4c5ca0f9570817c72e61839e0dbfa}


this method is called to automatically flush the cache 



Definition at line 483 of file Simulation.cpp.



References flushCache(), and m\_\-cacheAutomaticFlushEnabled.


\begin{DoxyCode}
{
    if (m_cacheAutomaticFlushEnabled) flushCache();
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_ad8a4c5ca0f9570817c72e61839e0dbfa_cgraph}
\end{center}
\end{figure}




Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_ad8a4c5ca0f9570817c72e61839e0dbfa_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a39d898714c1ed73be21522cc1cb35be5}{
\index{Simulation@{Simulation}!resizeGL@{resizeGL}}
\index{resizeGL@{resizeGL}!Simulation@{Simulation}}
\subsubsection[{resizeGL}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::resizeGL (
\begin{DoxyParamCaption}
\item[{const int}]{\_\-w, }
\item[{const int}]{\_\-h}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}protected\mbox{]}}}}
\label{class_simulation_a39d898714c1ed73be21522cc1cb35be5}


called whenever the window is re-\/sized 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-w} & the width of the resized window \\
\hline
\mbox{\tt in}  & {\em \_\-h} & the height of the resized window \\
\hline
\end{DoxyParams}


Definition at line 153 of file Simulation.cpp.


\begin{DoxyCode}
{
    //set the viewport
    glViewport(0, 0, _w, _h);

    //calculate the aspect ratio
    m_aspect = (float)_w / _h;

    //update camera aspect
    m_camera.setAspect(m_aspect);

    //update shaders ProjectionMatrix
    m_shaderLibrary->updateProjection(&m_camera);
}
\end{DoxyCode}
\hypertarget{class_simulation_a19cb8a965ede0f592864fb0c3473e020}{
\index{Simulation@{Simulation}!setCacheAutomaticFlushEnabled@{setCacheAutomaticFlushEnabled}}
\index{setCacheAutomaticFlushEnabled@{setCacheAutomaticFlushEnabled}!Simulation@{Simulation}}
\subsubsection[{setCacheAutomaticFlushEnabled}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::setCacheAutomaticFlushEnabled (
\begin{DoxyParamCaption}
\item[{const bool}]{\_\-v}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a19cb8a965ede0f592864fb0c3473e020}


set flag to determine whether automatic cache flushing is enabled 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-v} & updated flag \\
\hline
\end{DoxyParams}


Definition at line 106 of file Simulation.h.



References m\_\-cacheAutomaticFlushEnabled.


\begin{DoxyCode}
{ m_cacheAutomaticFlushEnabled = _v; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a19cb8a965ede0f592864fb0c3473e020_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_aa952718ebd3d5583556e10e7fb98dd7f}{
\index{Simulation@{Simulation}!setCacheAutomaticFlushInterval@{setCacheAutomaticFlushInterval}}
\index{setCacheAutomaticFlushInterval@{setCacheAutomaticFlushInterval}!Simulation@{Simulation}}
\subsubsection[{setCacheAutomaticFlushInterval}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::setCacheAutomaticFlushInterval (
\begin{DoxyParamCaption}
\item[{const int}]{\_\-v}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_aa952718ebd3d5583556e10e7fb98dd7f}


return automatic cache flushing interval 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-v} & updated value \\
\hline
\end{DoxyParams}


Definition at line 110 of file Simulation.h.



References m\_\-cacheAutomaticFlushInterval.


\begin{DoxyCode}
{ m_cacheAutomaticFlushInterval = _v; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_aa952718ebd3d5583556e10e7fb98dd7f_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_af5cc7d642bff6861b4ee2ca43bb9fc97}{
\index{Simulation@{Simulation}!setCacheEnabled@{setCacheEnabled}}
\index{setCacheEnabled@{setCacheEnabled}!Simulation@{Simulation}}
\subsubsection[{setCacheEnabled}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::setCacheEnabled (
\begin{DoxyParamCaption}
\item[{const bool}]{\_\-v}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_af5cc7d642bff6861b4ee2ca43bb9fc97}


set flag to determine whether cache is enabled 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-v} & updated flag \\
\hline
\end{DoxyParams}


Definition at line 98 of file Simulation.h.



References m\_\-cacheEnabled.


\begin{DoxyCode}
{ m_cacheEnabled = _v; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_af5cc7d642bff6861b4ee2ca43bb9fc97_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a7feaf359b5e698edf203683509c46c75}{
\index{Simulation@{Simulation}!setCacheExportBoundaryEnabled@{setCacheExportBoundaryEnabled}}
\index{setCacheExportBoundaryEnabled@{setCacheExportBoundaryEnabled}!Simulation@{Simulation}}
\subsubsection[{setCacheExportBoundaryEnabled}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::setCacheExportBoundaryEnabled (
\begin{DoxyParamCaption}
\item[{const bool}]{\_\-v}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a7feaf359b5e698edf203683509c46c75}


set flag to determine whether boundary is cached 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-v} & updated flag \\
\hline
\end{DoxyParams}


Definition at line 118 of file Simulation.h.



References m\_\-cacheExportBoundaryEnabled.


\begin{DoxyCode}
{ m_cacheExportBoundaryEnabled = _v; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a7feaf359b5e698edf203683509c46c75_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a92de3ffdc52af767508e341c731b54a7}{
\index{Simulation@{Simulation}!setCacheExportRBDEnabled@{setCacheExportRBDEnabled}}
\index{setCacheExportRBDEnabled@{setCacheExportRBDEnabled}!Simulation@{Simulation}}
\subsubsection[{setCacheExportRBDEnabled}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::setCacheExportRBDEnabled (
\begin{DoxyParamCaption}
\item[{const bool}]{\_\-v}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a92de3ffdc52af767508e341c731b54a7}


set flag to determine whether rbd is cached 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-v} & updated flag \\
\hline
\end{DoxyParams}


Definition at line 114 of file Simulation.h.



References m\_\-cacheExportRBDEnabled.


\begin{DoxyCode}
{ m_cacheExportRBDEnabled = _v; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a92de3ffdc52af767508e341c731b54a7_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a3a87685ffa6803a9f1bd734c073457fc}{
\index{Simulation@{Simulation}!setCacheSamplingInterval@{setCacheSamplingInterval}}
\index{setCacheSamplingInterval@{setCacheSamplingInterval}!Simulation@{Simulation}}
\subsubsection[{setCacheSamplingInterval}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::setCacheSamplingInterval (
\begin{DoxyParamCaption}
\item[{const int}]{\_\-v}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{class_simulation_a3a87685ffa6803a9f1bd734c073457fc}


return cache samping interval 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-v} & updated value \\
\hline
\end{DoxyParams}


Definition at line 102 of file Simulation.h.



References m\_\-cacheSamplingInterval.


\begin{DoxyCode}
{ m_cacheSamplingInterval = _v; }
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a3a87685ffa6803a9f1bd734c073457fc_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a5fa8ed10cec2fd5141843e605ecb8c11}{
\index{Simulation@{Simulation}!setup2DFrontView@{setup2DFrontView}}
\index{setup2DFrontView@{setup2DFrontView}!Simulation@{Simulation}}
\subsubsection[{setup2DFrontView}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::setup2DFrontView (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{class_simulation_a5fa8ed10cec2fd5141843e605ecb8c11}


this method is used to setup the 2D front view 



Definition at line 401 of file Simulation.cpp.



References m\_\-spinXFace, and m\_\-spinYFace.


\begin{DoxyCode}
{
    //2d front view enabled -> rotate our view to give a front view
    m_spinXFace=0;
    m_spinYFace=0;

    updateGL();
}
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a5fa8ed10cec2fd5141843e605ecb8c11_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_acb3f9b6452f68b267e110c0098c3c46e}{
\index{Simulation@{Simulation}!setup2DTopView@{setup2DTopView}}
\index{setup2DTopView@{setup2DTopView}!Simulation@{Simulation}}
\subsubsection[{setup2DTopView}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::setup2DTopView (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{class_simulation_acb3f9b6452f68b267e110c0098c3c46e}


this method is used to setup the 2D top view 



Definition at line 392 of file Simulation.cpp.



References m\_\-spinXFace, and m\_\-spinYFace.


\begin{DoxyCode}
{
    //2d top view enabled -> rotate our view to give a top view
    m_spinXFace=-90;
    m_spinYFace=0;

    updateGL();
}
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_acb3f9b6452f68b267e110c0098c3c46e_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a75e0e6b11b3c022ef533a5bab80cffe6}{
\index{Simulation@{Simulation}!timerEvent@{timerEvent}}
\index{timerEvent@{timerEvent}!Simulation@{Simulation}}
\subsubsection[{timerEvent}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::timerEvent (
\begin{DoxyParamCaption}
\item[{QTimerEvent $\ast$}]{\_\-event}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a75e0e6b11b3c022ef533a5bab80cffe6}


the timer event triggered from the timers 



Definition at line 236 of file Simulation.cpp.



References Solver::getEnableAutoFluidUpdate(), m\_\-environment, m\_\-fpsTimerEnabled, m\_\-frameCounter, m\_\-integration, m\_\-mainSimulationTimer, m\_\-solver, and Solver::updateFluid().


\begin{DoxyCode}
{
    //main simulation timer
    if (_event->timerId() == m_mainSimulationTimer)
    {
        //update fluid state if fluid's auto move is enabled
        if (m_solver->getEnableAutoFluidUpdate())
        {
            //update fluid
            m_solver->updateFluid(m_environment, m_integration);

            //refresh display
            updateGL();

            //update frame counter for fps
            if (m_fpsTimerEnabled) m_frameCounter++;
        }
    }
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a75e0e6b11b3c022ef533a5bab80cffe6_cgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_aed3abe33551f1826246230827cbaa71b}{
\index{Simulation@{Simulation}!toggleAutomaticCacheFlush@{toggleAutomaticCacheFlush}}
\index{toggleAutomaticCacheFlush@{toggleAutomaticCacheFlush}!Simulation@{Simulation}}
\subsubsection[{toggleAutomaticCacheFlush}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::toggleAutomaticCacheFlush (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{class_simulation_aed3abe33551f1826246230827cbaa71b}


this method toggles the automatic cache flush timer 



Definition at line 448 of file Simulation.cpp.



References m\_\-cacheAutomaticFlushEnabled, m\_\-cacheAutomaticFlushInterval, and m\_\-simulationCacheAutoFlushTimer.


\begin{DoxyCode}
{
    //stop timers
    m_simulationCacheAutoFlushTimer->stop();

    if (m_cacheAutomaticFlushEnabled)
    {
        //start timers
        m_simulationCacheAutoFlushTimer->start(m_cacheAutomaticFlushInterval);
    }
}
\end{DoxyCode}


Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_aed3abe33551f1826246230827cbaa71b_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a9cc32fae74d0e48ad7bd6aa23ba49eac}{
\index{Simulation@{Simulation}!toggleCache@{toggleCache}}
\index{toggleCache@{toggleCache}!Simulation@{Simulation}}
\subsubsection[{toggleCache}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::toggleCache (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{class_simulation_a9cc32fae74d0e48ad7bd6aa23ba49eac}


this method toggles the cache timer 



Definition at line 434 of file Simulation.cpp.



References m\_\-cacheEnabled, m\_\-cacheSamplingInterval, m\_\-simulationCacheTimer, and processSimulationCache().


\begin{DoxyCode}
{
    m_simulationCacheTimer->stop();

    if (m_cacheEnabled)
    {
        //cache current initial frame
        m_simulationCacheTimer->singleShot(0, this, SLOT(processSimulationCache()
      ));

        //start timers
        m_simulationCacheTimer->start(m_cacheSamplingInterval);
    }
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a9cc32fae74d0e48ad7bd6aa23ba49eac_cgraph}
\end{center}
\end{figure}




Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a9cc32fae74d0e48ad7bd6aa23ba49eac_icgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_a4013fd48f4c835032cc250a80964b5a4}{
\index{Simulation@{Simulation}!updateCameraZoom@{updateCameraZoom}}
\index{updateCameraZoom@{updateCameraZoom}!Simulation@{Simulation}}
\subsubsection[{updateCameraZoom}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::updateCameraZoom (
\begin{DoxyParamCaption}
\item[{const int}]{\_\-depth}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}slot\mbox{]}}}}
\label{class_simulation_a4013fd48f4c835032cc250a80964b5a4}


called when the camera zoom slider value is changed in the GUI; it slides the camera along its N vector 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em \_\-depth} & the zoom factor to set to the camera \\
\hline
\end{DoxyParams}


Definition at line 370 of file Simulation.cpp.



References m\_\-camera, m\_\-lastCamZ, m\_\-shaderLibrary, and ShaderLibrary::updateViewProjection().


\begin{DoxyCode}
{
    //calculate the relative change in Z value
    float newZ = (float)(-depth);
    float changeInZ = newZ - m_lastCamZ;

    //calculate the small change in N that corresponds to the change in Z
    float dn = changeInZ / m_camera.getN().m_z;

    //slide the camera along the N vector by the change in N
    m_camera.slide(0, 0, dn);

    //save the new Z value
    m_lastCamZ = m_camera.getEye().m_z;

    //update view projection matrices of camera
    if ((m_shaderLibrary != NULL) && (m_shaderLibrary != 0)) m_shaderLibrary->
      updateViewProjection(&m_camera);

    //refresh display
    updateGL();
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_a4013fd48f4c835032cc250a80964b5a4_cgraph}
\end{center}
\end{figure}


\hypertarget{class_simulation_ae0b5c44bbf3d36c84c91dd872aabf243}{
\index{Simulation@{Simulation}!updateFPSTimer@{updateFPSTimer}}
\index{updateFPSTimer@{updateFPSTimer}!Simulation@{Simulation}}
\subsubsection[{updateFPSTimer}]{\setlength{\rightskip}{0pt plus 5cm}void Simulation::updateFPSTimer (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{class_simulation_ae0b5c44bbf3d36c84c91dd872aabf243}


this method updates the states of timers after the simulation of fluid is started/stopped 



Definition at line 410 of file Simulation.cpp.



References Solver::getEnableAutoFluidUpdate(), m\_\-fpsTimer, m\_\-fpsTimerEnabled, m\_\-frameCounter, and m\_\-solver.


\begin{DoxyCode}
{
    if (m_solver->getEnableAutoFluidUpdate())
    {
        //start timer
        if (m_fpsTimerEnabled)
        {
            m_frameCounter = 0;
            m_fpsTimer->start();
        }
    }
    else
    {
        //stop timer
        m_fpsTimer->stop();
    }
}
\end{DoxyCode}


Here is the call graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_ae0b5c44bbf3d36c84c91dd872aabf243_cgraph}
\end{center}
\end{figure}




Here is the caller graph for this function:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{class_simulation_ae0b5c44bbf3d36c84c91dd872aabf243_icgraph}
\end{center}
\end{figure}




\subsection{Member Data Documentation}
\hypertarget{class_simulation_abda6a0ce09dba152142cd8b779a235ba}{
\index{Simulation@{Simulation}!m\_\-aspect@{m\_\-aspect}}
\index{m\_\-aspect@{m\_\-aspect}!Simulation@{Simulation}}
\subsubsection[{m\_\-aspect}]{\setlength{\rightskip}{0pt plus 5cm}float {\bf Simulation::m\_\-aspect}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_abda6a0ce09dba152142cd8b779a235ba}


aspect ratio of the camera 



Definition at line 179 of file Simulation.h.

\hypertarget{class_simulation_aae62058ff9bb93a433685384d63f26b3}{
\index{Simulation@{Simulation}!m\_\-cache@{m\_\-cache}}
\index{m\_\-cache@{m\_\-cache}!Simulation@{Simulation}}
\subsubsection[{m\_\-cache}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Cache}$\ast$ {\bf Simulation::m\_\-cache}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_aae62058ff9bb93a433685384d63f26b3}


cache 



Definition at line 209 of file Simulation.h.

\hypertarget{class_simulation_a5202d1ba26da5e3abbc1af3b5a760cd4}{
\index{Simulation@{Simulation}!m\_\-cacheAutomaticFlushEnabled@{m\_\-cacheAutomaticFlushEnabled}}
\index{m\_\-cacheAutomaticFlushEnabled@{m\_\-cacheAutomaticFlushEnabled}!Simulation@{Simulation}}
\subsubsection[{m\_\-cacheAutomaticFlushEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf Simulation::m\_\-cacheAutomaticFlushEnabled}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a5202d1ba26da5e3abbc1af3b5a760cd4}


flag to determine automatic cache flushing is enabled 



Definition at line 242 of file Simulation.h.

\hypertarget{class_simulation_afb2e47a4aa797855e428378cf1294409}{
\index{Simulation@{Simulation}!m\_\-cacheAutomaticFlushInterval@{m\_\-cacheAutomaticFlushInterval}}
\index{m\_\-cacheAutomaticFlushInterval@{m\_\-cacheAutomaticFlushInterval}!Simulation@{Simulation}}
\subsubsection[{m\_\-cacheAutomaticFlushInterval}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-cacheAutomaticFlushInterval}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_afb2e47a4aa797855e428378cf1294409}


automatic cache flushing interval 



Definition at line 245 of file Simulation.h.

\hypertarget{class_simulation_acc7915a7ed4a9f75c4b4288b451433d1}{
\index{Simulation@{Simulation}!m\_\-cacheEnabled@{m\_\-cacheEnabled}}
\index{m\_\-cacheEnabled@{m\_\-cacheEnabled}!Simulation@{Simulation}}
\subsubsection[{m\_\-cacheEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf Simulation::m\_\-cacheEnabled}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_acc7915a7ed4a9f75c4b4288b451433d1}


flag to determine if cache is enabled 



Definition at line 236 of file Simulation.h.

\hypertarget{class_simulation_a789806513f6abfc274479a379f499c7d}{
\index{Simulation@{Simulation}!m\_\-cacheExportBoundaryEnabled@{m\_\-cacheExportBoundaryEnabled}}
\index{m\_\-cacheExportBoundaryEnabled@{m\_\-cacheExportBoundaryEnabled}!Simulation@{Simulation}}
\subsubsection[{m\_\-cacheExportBoundaryEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf Simulation::m\_\-cacheExportBoundaryEnabled}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a789806513f6abfc274479a379f499c7d}


flag to determine if boundary is cached 



Definition at line 251 of file Simulation.h.

\hypertarget{class_simulation_ac7c9f2c16923e90dc8903f9083ca9e2c}{
\index{Simulation@{Simulation}!m\_\-cacheExportRBDEnabled@{m\_\-cacheExportRBDEnabled}}
\index{m\_\-cacheExportRBDEnabled@{m\_\-cacheExportRBDEnabled}!Simulation@{Simulation}}
\subsubsection[{m\_\-cacheExportRBDEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf Simulation::m\_\-cacheExportRBDEnabled}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_ac7c9f2c16923e90dc8903f9083ca9e2c}


flag to determine if rbd is cached 



Definition at line 248 of file Simulation.h.

\hypertarget{class_simulation_a3d4535e9d5af4426e1c83fcbc3517449}{
\index{Simulation@{Simulation}!m\_\-cachePath@{m\_\-cachePath}}
\index{m\_\-cachePath@{m\_\-cachePath}!Simulation@{Simulation}}
\subsubsection[{m\_\-cachePath}]{\setlength{\rightskip}{0pt plus 5cm}std::string {\bf Simulation::m\_\-cachePath}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a3d4535e9d5af4426e1c83fcbc3517449}


the path of the cache on disk 



Definition at line 254 of file Simulation.h.

\hypertarget{class_simulation_a945f9264f587eb677ccc6574ca85d65e}{
\index{Simulation@{Simulation}!m\_\-cacheSamplingInterval@{m\_\-cacheSamplingInterval}}
\index{m\_\-cacheSamplingInterval@{m\_\-cacheSamplingInterval}!Simulation@{Simulation}}
\subsubsection[{m\_\-cacheSamplingInterval}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-cacheSamplingInterval}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a945f9264f587eb677ccc6574ca85d65e}


cache samping interval 



Definition at line 239 of file Simulation.h.

\hypertarget{class_simulation_af0c9404e4c5c24c154283fc7f843d828}{
\index{Simulation@{Simulation}!m\_\-camera@{m\_\-camera}}
\index{m\_\-camera@{m\_\-camera}!Simulation@{Simulation}}
\subsubsection[{m\_\-camera}]{\setlength{\rightskip}{0pt plus 5cm}ngl::Camera {\bf Simulation::m\_\-camera}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_af0c9404e4c5c24c154283fc7f843d828}


ngl camera object 



Definition at line 194 of file Simulation.h.

\hypertarget{class_simulation_a59064177bd41ff1e01feb00afcf4b487}{
\index{Simulation@{Simulation}!m\_\-drawHelp@{m\_\-drawHelp}}
\index{m\_\-drawHelp@{m\_\-drawHelp}!Simulation@{Simulation}}
\subsubsection[{m\_\-drawHelp}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf Simulation::m\_\-drawHelp}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a59064177bd41ff1e01feb00afcf4b487}


toggle help flag 



Definition at line 176 of file Simulation.h.

\hypertarget{class_simulation_a1b0107415c2dcb91934280857751b2aa}{
\index{Simulation@{Simulation}!m\_\-environment@{m\_\-environment}}
\index{m\_\-environment@{m\_\-environment}!Simulation@{Simulation}}
\subsubsection[{m\_\-environment}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Environment}$\ast$ {\bf Simulation::m\_\-environment}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a1b0107415c2dcb91934280857751b2aa}


environment 



Definition at line 203 of file Simulation.h.

\hypertarget{class_simulation_a2a4f2cfb5609a76f43fb478a0ea454f6}{
\index{Simulation@{Simulation}!m\_\-fpsTimer@{m\_\-fpsTimer}}
\index{m\_\-fpsTimer@{m\_\-fpsTimer}!Simulation@{Simulation}}
\subsubsection[{m\_\-fpsTimer}]{\setlength{\rightskip}{0pt plus 5cm}QTimer$\ast$ {\bf Simulation::m\_\-fpsTimer}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a2a4f2cfb5609a76f43fb478a0ea454f6}


fps timer with interval = 1 s 



Definition at line 221 of file Simulation.h.

\hypertarget{class_simulation_aed57e8a29c33ed01e10294521afababd}{
\index{Simulation@{Simulation}!m\_\-fpsTimerEnabled@{m\_\-fpsTimerEnabled}}
\index{m\_\-fpsTimerEnabled@{m\_\-fpsTimerEnabled}!Simulation@{Simulation}}
\subsubsection[{m\_\-fpsTimerEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf Simulation::m\_\-fpsTimerEnabled}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_aed57e8a29c33ed01e10294521afababd}


fps timer toggle 



Definition at line 224 of file Simulation.h.

\hypertarget{class_simulation_a0c8c6edf43d816404c6222dd93c49fe6}{
\index{Simulation@{Simulation}!m\_\-frameCounter@{m\_\-frameCounter}}
\index{m\_\-frameCounter@{m\_\-frameCounter}!Simulation@{Simulation}}
\subsubsection[{m\_\-frameCounter}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-frameCounter}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a0c8c6edf43d816404c6222dd93c49fe6}


counter to keep track of number of frames for fps calculation 



Definition at line 215 of file Simulation.h.

\hypertarget{class_simulation_a457b9396fc6681443f704b3ed17b61d5}{
\index{Simulation@{Simulation}!m\_\-frameRate@{m\_\-frameRate}}
\index{m\_\-frameRate@{m\_\-frameRate}!Simulation@{Simulation}}
\subsubsection[{m\_\-frameRate}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-frameRate}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a457b9396fc6681443f704b3ed17b61d5}


frame update rate 



Definition at line 185 of file Simulation.h.

\hypertarget{class_simulation_a44ee516f95af7bbdce7f7853428f3a9f}{
\index{Simulation@{Simulation}!m\_\-integration@{m\_\-integration}}
\index{m\_\-integration@{m\_\-integration}!Simulation@{Simulation}}
\subsubsection[{m\_\-integration}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Integration}$\ast$ {\bf Simulation::m\_\-integration}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a44ee516f95af7bbdce7f7853428f3a9f}


integration 



Definition at line 206 of file Simulation.h.

\hypertarget{class_simulation_aa5b6caae07baa87fc6bf2cd2df3ce9a3}{
\index{Simulation@{Simulation}!m\_\-lastCamZ@{m\_\-lastCamZ}}
\index{m\_\-lastCamZ@{m\_\-lastCamZ}!Simulation@{Simulation}}
\subsubsection[{m\_\-lastCamZ}]{\setlength{\rightskip}{0pt plus 5cm}float {\bf Simulation::m\_\-lastCamZ}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_aa5b6caae07baa87fc6bf2cd2df3ce9a3}


the last depth of a camera zoom operation 



Definition at line 212 of file Simulation.h.

\hypertarget{class_simulation_a32878b0a743e6bd06aa435560618bcca}{
\index{Simulation@{Simulation}!m\_\-light@{m\_\-light}}
\index{m\_\-light@{m\_\-light}!Simulation@{Simulation}}
\subsubsection[{m\_\-light}]{\setlength{\rightskip}{0pt plus 5cm}ngl::Light {\bf Simulation::m\_\-light}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a32878b0a743e6bd06aa435560618bcca}


ngl light object 



Definition at line 191 of file Simulation.h.

\hypertarget{class_simulation_a4d073bafa3112526d3b0cf9e11a1eead}{
\index{Simulation@{Simulation}!m\_\-mainSimulationTimer@{m\_\-mainSimulationTimer}}
\index{m\_\-mainSimulationTimer@{m\_\-mainSimulationTimer}!Simulation@{Simulation}}
\subsubsection[{m\_\-mainSimulationTimer}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-mainSimulationTimer}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a4d073bafa3112526d3b0cf9e11a1eead}


main simulation timer (continuous ticking) 



Definition at line 218 of file Simulation.h.

\hypertarget{class_simulation_a487a8da0a159a86159b39b0fb0a7ea68}{
\index{Simulation@{Simulation}!m\_\-mouseMoveSensitivity@{m\_\-mouseMoveSensitivity}}
\index{m\_\-mouseMoveSensitivity@{m\_\-mouseMoveSensitivity}!Simulation@{Simulation}}
\subsubsection[{m\_\-mouseMoveSensitivity}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-mouseMoveSensitivity}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a487a8da0a159a86159b39b0fb0a7ea68}


mouse move sensitivity 



Definition at line 182 of file Simulation.h.

\hypertarget{class_simulation_aa585390cafbfeb3cdd7e4da129f27ad2}{
\index{Simulation@{Simulation}!m\_\-move@{m\_\-move}}
\index{m\_\-move@{m\_\-move}!Simulation@{Simulation}}
\subsubsection[{m\_\-move}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf Simulation::m\_\-move}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_aa585390cafbfeb3cdd7e4da129f27ad2}


flag to indicate if the right mouse is pressed for (x,y) mouse movement 



Definition at line 167 of file Simulation.h.

\hypertarget{class_simulation_a824bd0db2421e8a1129837395ee938d4}{
\index{Simulation@{Simulation}!m\_\-moveX@{m\_\-moveX}}
\index{m\_\-moveX@{m\_\-moveX}!Simulation@{Simulation}}
\subsubsection[{m\_\-moveX}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-moveX}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a824bd0db2421e8a1129837395ee938d4}


right mouse camera movement x value 



Definition at line 161 of file Simulation.h.

\hypertarget{class_simulation_a9ae645b702669c78be080ee35dcfc656}{
\index{Simulation@{Simulation}!m\_\-moveY@{m\_\-moveY}}
\index{m\_\-moveY@{m\_\-moveY}!Simulation@{Simulation}}
\subsubsection[{m\_\-moveY}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-moveY}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a9ae645b702669c78be080ee35dcfc656}


right mouse camera movement y value 



Definition at line 164 of file Simulation.h.

\hypertarget{class_simulation_aa2942ca701a2560de7f3bc4aa5c36cf6}{
\index{Simulation@{Simulation}!m\_\-origMoveX@{m\_\-origMoveX}}
\index{m\_\-origMoveX@{m\_\-origMoveX}!Simulation@{Simulation}}
\subsubsection[{m\_\-origMoveX}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-origMoveX}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_aa2942ca701a2560de7f3bc4aa5c36cf6}


starting x position of the right mouse 



Definition at line 170 of file Simulation.h.

\hypertarget{class_simulation_a156d1e72405c62e75207979bfdf8aa0d}{
\index{Simulation@{Simulation}!m\_\-origMoveY@{m\_\-origMoveY}}
\index{m\_\-origMoveY@{m\_\-origMoveY}!Simulation@{Simulation}}
\subsubsection[{m\_\-origMoveY}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-origMoveY}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a156d1e72405c62e75207979bfdf8aa0d}


starting y position of the right mouse 



Definition at line 173 of file Simulation.h.

\hypertarget{class_simulation_a6422d3666ba6798f24b26efeb282732b}{
\index{Simulation@{Simulation}!m\_\-origX@{m\_\-origX}}
\index{m\_\-origX@{m\_\-origX}!Simulation@{Simulation}}
\subsubsection[{m\_\-origX}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-origX}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a6422d3666ba6798f24b26efeb282732b}


the previous x mouse value 



Definition at line 155 of file Simulation.h.

\hypertarget{class_simulation_aeddd48fda58be3d3101acd9089bdb59e}{
\index{Simulation@{Simulation}!m\_\-origY@{m\_\-origY}}
\index{m\_\-origY@{m\_\-origY}!Simulation@{Simulation}}
\subsubsection[{m\_\-origY}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-origY}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_aeddd48fda58be3d3101acd9089bdb59e}


the previous y mouse value 



Definition at line 158 of file Simulation.h.

\hypertarget{class_simulation_abecf7cd8f4966dd8e19776fecd2be11c}{
\index{Simulation@{Simulation}!m\_\-rotate@{m\_\-rotate}}
\index{m\_\-rotate@{m\_\-rotate}!Simulation@{Simulation}}
\subsubsection[{m\_\-rotate}]{\setlength{\rightskip}{0pt plus 5cm}bool {\bf Simulation::m\_\-rotate}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_abecf7cd8f4966dd8e19776fecd2be11c}


flag to indicate if the mouse button is pressed when dragging 



Definition at line 152 of file Simulation.h.

\hypertarget{class_simulation_a83383544daf0879e0c813082c8079e86}{
\index{Simulation@{Simulation}!m\_\-shaderLibrary@{m\_\-shaderLibrary}}
\index{m\_\-shaderLibrary@{m\_\-shaderLibrary}!Simulation@{Simulation}}
\subsubsection[{m\_\-shaderLibrary}]{\setlength{\rightskip}{0pt plus 5cm}{\bf ShaderLibrary}$\ast$ {\bf Simulation::m\_\-shaderLibrary}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a83383544daf0879e0c813082c8079e86}


shader library 



Definition at line 197 of file Simulation.h.

\hypertarget{class_simulation_a90dc06d8b8ae5e1897f72895d3067943}{
\index{Simulation@{Simulation}!m\_\-simulationCacheAutoFlushTimer@{m\_\-simulationCacheAutoFlushTimer}}
\index{m\_\-simulationCacheAutoFlushTimer@{m\_\-simulationCacheAutoFlushTimer}!Simulation@{Simulation}}
\subsubsection[{m\_\-simulationCacheAutoFlushTimer}]{\setlength{\rightskip}{0pt plus 5cm}QTimer$\ast$ {\bf Simulation::m\_\-simulationCacheAutoFlushTimer}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a90dc06d8b8ae5e1897f72895d3067943}


simulation cache autoFlush timer 



Definition at line 230 of file Simulation.h.

\hypertarget{class_simulation_af359882ee350f8cee694e81d415585b5}{
\index{Simulation@{Simulation}!m\_\-simulationCacheFrameNumber@{m\_\-simulationCacheFrameNumber}}
\index{m\_\-simulationCacheFrameNumber@{m\_\-simulationCacheFrameNumber}!Simulation@{Simulation}}
\subsubsection[{m\_\-simulationCacheFrameNumber}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-simulationCacheFrameNumber}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_af359882ee350f8cee694e81d415585b5}


cache frame number 



Definition at line 233 of file Simulation.h.

\hypertarget{class_simulation_ab0b9b0ee02566961f1cb7f7dc82c140a}{
\index{Simulation@{Simulation}!m\_\-simulationCacheTimer@{m\_\-simulationCacheTimer}}
\index{m\_\-simulationCacheTimer@{m\_\-simulationCacheTimer}!Simulation@{Simulation}}
\subsubsection[{m\_\-simulationCacheTimer}]{\setlength{\rightskip}{0pt plus 5cm}QTimer$\ast$ {\bf Simulation::m\_\-simulationCacheTimer}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_ab0b9b0ee02566961f1cb7f7dc82c140a}


simulation cache timer 



Definition at line 227 of file Simulation.h.

\hypertarget{class_simulation_a642455fef792c7129fcf18887da865d9}{
\index{Simulation@{Simulation}!m\_\-solver@{m\_\-solver}}
\index{m\_\-solver@{m\_\-solver}!Simulation@{Simulation}}
\subsubsection[{m\_\-solver}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Solver}$\ast$ {\bf Simulation::m\_\-solver}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a642455fef792c7129fcf18887da865d9}


fluid solver 



Definition at line 200 of file Simulation.h.

\hypertarget{class_simulation_a5611b623f192c406d20d99cf99cbd0d9}{
\index{Simulation@{Simulation}!m\_\-spinXFace@{m\_\-spinXFace}}
\index{m\_\-spinXFace@{m\_\-spinXFace}!Simulation@{Simulation}}
\subsubsection[{m\_\-spinXFace}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-spinXFace}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_a5611b623f192c406d20d99cf99cbd0d9}


the x rotation mouse value 



Definition at line 146 of file Simulation.h.

\hypertarget{class_simulation_acaba6e4bd63518e5edd5443f6d10467c}{
\index{Simulation@{Simulation}!m\_\-spinYFace@{m\_\-spinYFace}}
\index{m\_\-spinYFace@{m\_\-spinYFace}!Simulation@{Simulation}}
\subsubsection[{m\_\-spinYFace}]{\setlength{\rightskip}{0pt plus 5cm}int {\bf Simulation::m\_\-spinYFace}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_acaba6e4bd63518e5edd5443f6d10467c}


the y rotation mouse value 



Definition at line 149 of file Simulation.h.

\hypertarget{class_simulation_ae8af4283c95bf52522f7cae6e58fa74b}{
\index{Simulation@{Simulation}!m\_\-transformStack@{m\_\-transformStack}}
\index{m\_\-transformStack@{m\_\-transformStack}!Simulation@{Simulation}}
\subsubsection[{m\_\-transformStack}]{\setlength{\rightskip}{0pt plus 5cm}ngl::TransformStack {\bf Simulation::m\_\-transformStack}\hspace{0.3cm}{\ttfamily  \mbox{[}private\mbox{]}}}}
\label{class_simulation_ae8af4283c95bf52522f7cae6e58fa74b}


global transform stack 



Definition at line 188 of file Simulation.h.



The documentation for this class was generated from the following files:\begin{DoxyCompactItemize}
\item 
include/\hyperlink{_simulation_8h}{Simulation.h}\item 
src/\hyperlink{_simulation_8cpp}{Simulation.cpp}\end{DoxyCompactItemize}
